<!--{Atemplate tpl/header}-->

<script>
function checkall(value) {
	if(value=='0'){
		jQuery(".checkbox").attr("checked","checked");
		jQuery("#chkall_del").removeAttr("disabled","disabled");
	}
	if(value=='1'){
		jQuery(".checkbox").removeAttr("checked","checked");
		jQuery("#chkall_del").attr("disabled","disabled");
	}
	if(value=='auth'){
		var chkall = jQuery("input:checked").val();
		if(chkall == null){
			alert('请先选择');
			return false;
		}else{
			return true;
		}
	}
}

jQuery(function(){
	jQuery(".checkbox").change(function (){
		if(jQuery("input:checked").val()){
			jQuery("#chkall_del").removeAttr("disabled","disabled");
		}else{
			jQuery("#chkall_del").attr("disabled","disabled");
		}
	});
})
</script>
<form method="post" action="">
<!--
<div class="search_admin">
	<font color=red><b>(查询标题或标签):</b></font>
	<input type="text" name="key" value="">
	<input type="submit" name="submit" value="搜索" onClick="javascript:form.action='';" />
	当前查询:<font color=red><b>$key</b></font>
</div>
搜索 end-->

<table class="-table">
	<tr>
		<th><b><a href="$page->theurl-aorder-domain,$pages->neworder$pages->other">虚拟主机</a></b></th>
		<th><b><a href="$page->theurl-aorder-domainroot,$pages->neworder$pages->other">修改时间</a></b></th>
		<th><b><a href="$page->theurl-aorder-domainroot,$pages->neworder$pages->other">大小</a></b></th>
		<th><b><a href="$page->theurl-aorder-domainroot,$pages->neworder$pages->other">是否启用</a></b></th>
		<th><b>管理</b></th>
	</tr>
<!--{loop $host $key $val}-->
	<tr>
		<td>$val[name]</td>
		<td>$val[mtimedate]</td>
		<td>$val[sizes]</td>
		<td><!--{if $val[ext]=='conf'}-->启用<!--{else}-->未启用<!--{/if}--></td>
		<td>
			<a href="$this->Amodr-rewrite_up?file=$val[names]">编辑</a>
			<input type="submit" value="删除" onClick="javascript:if(confirm('确实要删除吗?')) form.action='$this->Amodr-rewrite_del?file=$val[names]';" />
		</td>
	</tr>
<!--{/loop}-->
	<tr>
		<td colspan="10">
			<input type="button" onclick="javascript:checkall(0);" value="全选" >
			<input type="button" onclick="javascript:checkall(1);" value="反选">
			<input type="submit" id="chkall_del" disabled="disabled" value="删除选择" onClick="javascript:form.action='$this->Amodr-delall';" />
			<input type="submit" name="submit" value="全部保存" onClick="javascript:form.action='$this->Amodr-save';" />
		</td>
	</tr>
</table>

</form>
<!-- 分页 -->
$pages->html

<!--{Atemplate tpl/footer}-->